﻿using AutoMapper;
using Model.Entitys;
using Model.Dto;

namespace Common.Config
{
    public class AutoMapperConfigs: Profile
    {
        /// <summary>
        /// 在构造函数中配置映射关系
        /// </summary>
        public AutoMapperConfigs()
        {
            //从A => B
            //CreateMap<Model.Entitys.User, UserRes>();
            //CreateMap<RegisterReq, Model.Entitys.User>();

            CreateMap<Users, UserRes>();
            CreateMap<UserReq, Users>();
        }
    }
}
